<!-- 钱包： yx -->

<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>我的钱包</title>
		<link rel="stylesheet" href="css/rmodal-no-bootstrap.css" type="text/css" />
		<link href="https://cdn.bootcss.com/bootstrap/4.0.0/css/bootstrap.min.css" rel="stylesheet">
		<link rel="stylesheet" href="https://cdn.bootcss.com/animate.css/3.5.2/animate.min.css">
		<script type="text/javascript" src="./js/rmodal.js"></script>
		<link href="/chat/css/wallet.css" rel="stylesheet" type="text/css"/>
		<link href="/chat/css/rmodal-no-bootstrap.css"/>
	 	<link rel="stylesheet" href="css/mall.css" type="text/css" />
		<script type="text/javascript">
		        window.onload = function() {
		            var modal = new RModal(document.getElementById('modal'), {
		                beforeOpen: function(next) {
		                    console.log('beforeOpen');
		                    next();
		                }
		                , afterOpen: function() {
		                    console.log('opened');
		                }
		
		                , beforeClose: function(next) {
		                    console.log('beforeClose');
		                    next();
		                }
		                , afterClose: function() {
		                    console.log('closed');
		                }
		            });
		
		            document.addEventListener('keydown', function(ev) {
		                modal.keydown(ev);
		            }, false);
		
		            document.getElementById('butt1').addEventListener("click", function(ev) {
		                ev.preventDefault();
		                modal.open();
		            }, false);
					document.getElementById('butt2').addEventListener("click", function(ev) {
					    ev.preventDefault();
					    modal.open();
					}, false);
		
		            window.modal = modal;
		        }
		</script>
	</head>
	<body>
	      <div id="child_header" style="height: 45px;width: 100%">
                <div class="goback"><a href="/chat/personcenter"><i></i></a></div>
                <div class="current_location"><span>我的钱包</span></div>
          </div>
		
		<div id="pag">
			<div id="money-log">
				<img src="img/钱.png" >
			</div>
			<div id="my-balance">
				我的余额
			</div>
			<div id="balance">
				¥:[[${balance}]]
			</div>
			<div onclick="but1()" id="butt1" >
				充值
			</div>
			<div onclick="but2()" id="butt2">
				提现
			</div>
		</div>
		<div id="butt-type">
			<input type="hidden" id="butType" value="5" />
			<input type="hidden" id="useri" th:value="${userId}" />
		</div>
		<!--模态窗口-->
		<div id="modal" class="modal">
		    <div class="modal-dialog animated">
		        <div class="modal-content">
		                <div class="modal-header">
		                    <strong>欢迎使用YOGAorder钱包！请输入金额</strong>
		                </div>
		                <div class="modal-body">
		                    <div class="form-group">
		                        <div class="input-group col-xs-7">
		                            <input type="text" id="moneySum" value="" />
		                        </div>
		                    </div>
		                </div>
			
		                <div class="modal-footer">
		                    <button class="btn btn-default" type="button" onclick="modal.close()">取消</button>
		                    <button class="btn btn-primary" type="submit" th:onclick="'javascript:money(\''+${userId}+'\',0);'">确认</button>
		                </div>
		        </div>
		    </div>
		</div>
		<script src="/chat/js/wallet.js"></script>
		<script src="/chat/js/jquery-3.4.1.min.js"></script>
	</body>
</html>
